<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
	<script src='vue.js'></script>
</head>
<body>
	<div id="app">
		<div v-show="show">{{message}}</div>
		<div v-if="show">{{message}}</div>

		<div v-if="flag==='a'">this is A</div>
		<div v-else-if="flag==='b'">this is B</div>
		<div v-else>this is others</div>

		<div v-if="show">
			用户名: <input type="text" key="username">
		</div>
		<div v-else>
			邮箱: <input type="text" key="email">
		</div>
	</div>

	<script>
		var app = new Vue({
			el: '#app',
			data: {
				message: 'this is message',
				show: false,
				flag: 'a'
			}
		})

		
	</script>
</body>
</html>